package cn.liumouren.jzxd.dao;

import cn.liumouren.jzxd.entity.News;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * 
 * 
 * @author Freeman Liu
 * @email llw599502537@gmail.com
 * @date 2020-10-30 16:28:20
 */
@Mapper
public interface NewsDao extends BaseMapper<News> {

    @Select("SELECT tb_news.* FROM `tb_news_classify`,`tb_news` WHERE news_id = id AND classify_id = #{classifyId}")
    List<News> getAllNewsByClassifyId(String classifyId);
}
